<?php
namespace action\articles;
use \cass\Cache;
class indexAction extends \cass\Action {

    /**
     * Méthode de cache
     * @return Integer Type de cache (Cache::<type>)
     */
    public function cache() {
	return array(
	    'execute' => Cache::SESSION_TWICE
	);
    }

    /**
     * Méthode de l'index
     */    
    public function execute() { 
        $this->setTitle('Articles');
        $this->addToCss('actions/articles/index.css');

        $this->categories = $this->doctrine->getRepository('ArticlesCategory')->findAll();
    }
}